package com.bsy.network.response

/**
 * @author Sincerity
 * @date   2023/2/24 13:10
 * @desc   通用数据类
 */
data class BaseResponse<out T>(
    val data: T?,
    val msg: String = "",//错误信息
    val code: Int = 0//错误信息
) {

    /**
     * 判定接口返回是否正常
     */
    fun isSuccess(): Boolean {
        return code == 0 || code == 200
    }
}
